<include file="public@header" />
<link rel="stylesheet" type="text/css" href="__STATIC__/layui/css/layui.css">
</head>
<body>
	<div class="wrap">
		<ul class="nav nav-tabs">
			<li><a href="{:url('admin_index/index')}">用户列表</a></li>
        	<li class="active"><a href="{:url('admin_index/add')}">新增用户</a></li>
		</ul>
		<form method="post" class="form-horizontal js-ajax-form margin-top-20" action="{:url('admin_index/add')}">
			<div class="form-group">
				<label for="input-name" class="col-sm-2 control-label"><span class="form-required">*</span>区域</label>
				<div class="col-md-6 col-sm-10">
					<div class="layui-form">
				        <div class="layui-form-item" id="area-picker">
				            <div class="layui-input-inline" style="width: 200px;">
				                <select name="province" class="province-selector" data-value="" lay-filter="province-1">
				                    <option value="">请选择省</option>
				                </select>
				            </div>
				            <div class="layui-input-inline" style="width: 200px;">
				                <select name="city" class="city-selector" data-value="" lay-filter="city-1">
				                    <option value="">请选择市</option>
				                </select>
				            </div>
				            <div class="layui-input-inline" style="width: 200px;">
				                <select name="county" class="county-selector" data-value="" lay-filter="county-1">
				                    <option value="">请选择区</option>
				                </select>
				            </div>
				        </div>
				    </div>
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-2 control-label"><span class="form-required">*</span>手机号</label>
				<div class="col-md-6 col-sm-10">
					<input type="text" class="form-control" name="mobile">
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-2 control-label"><span class="form-required">*</span>邮箱</label>
				<div class="col-md-6 col-sm-10">
					<input type="text" class="form-control" name="user_email">
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-2 control-label"><span class="form-required">*</span>{:lang('PASSWORD')}</label>
				<div class="col-md-6 col-sm-10">
					<input type="text" class="form-control" name="user_pass" placeholder="******">
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-2 control-label"><span class="form-required">*</span>推荐码</label>
				<div class="col-md-6 col-sm-10">
					<input type="text" class="form-control" name="recommender_code">
				</div>
			</div>
			<div class="form-group">
				<div class="col-sm-offset-2 col-sm-10">
					<button type="submit" class="btn btn-primary js-ajax-submit">{:lang('ADD')}</button>
				</div>
			</div>
		</form>
	</div>
	<script src="__STATIC__/js/admin.js"></script>
	<script src="__STATIC__/layui/layui.js"></script>
	<script type="text/javascript">
		//配置插件目录
        layui.config({
            base: '__STATIC__/mods/'
            , version: '1.0'
        });
        //一般直接写在一个js文件中
        layui.use(['layarea'], function () {
            var layarea = layui.layarea;

            layarea.render({
                elem: '#area-picker',
                change: function (res) {
                    //选择结果
                    console.log(res);
                }
            });
        });
	</script>
</body>
</html>